package com.wcs.exam.controller.admin.resp;

import com.fasterxml.jackson.annotation.JsonFormat;
import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.io.Serial;
import java.util.List;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

/**
 * <p>
 * Admin-用户信息-查看响应对象
 * </p>
 *
 * @author wcs
 * @since 2025-03-13
 */
@Getter
@Setter
@Accessors(chain = true)
@Schema(description = "Admin-用户信息-查看响应对象")
public class AdminUsersViewResp implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    @Schema(description = "主键")
    private Long id;

    @Schema(description = "手机号码")
    private String mobile;

    @Schema(description = "密码盐")
    private String mobileSalt;

    @Schema(description = "登录密码")
    private String mobilePsw;

    @Schema(description = "昵称")
    private String nickname;

    @Schema(description = "用户性别(1男，2女，3保密)")
    private Integer userSex;

    @Schema(description = "出生时间")
    private LocalDate userAge;

    @Schema(description = "用户头像")
    private String userHead;

    @Schema(description = "微信唯一ID")
    private String unionId;

    @Schema(description = "微信OpenId")
    private String openId;

    @Schema(description = "城市")
    private String city;

    @Schema(description = "省份")
    private String province;

    @Schema(description = "国家")
    private String country;

    @Schema(description = "注册来源")
    private Integer registerSource;

    @Schema(description = "真实姓名")
    private String realName;

    @Schema(description = "身份证号")
    private String idCard;

    @Schema(description = "人脸识别最佳照片")
    private String bestFrame;

    @Schema(description = "人脸识别相似度")
    private BigDecimal faceSim;

    @Schema(description = "人脸错误次数")
    private Integer faceErrorCount;

    @Schema(description = "实名认证状态(1:未认证、2:已认证)")
    private Integer certificationStatus;

    @Schema(description = "备注")
    private String remark;

    @Schema(description = "状态(1:正常，0:禁用)")
    private Integer status;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Schema(description = "创建时间")
    private LocalDateTime gmtCreate;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Schema(description = "修改时间")
    private LocalDateTime gmtModified;

    /*----------------------------------- 拓展信息 -----------------------------------*/

    @Schema(description = "标签ID集合")
    private List<Tag> tags;

    @Data
    public static class Tag implements Serializable {

        @Serial
        private static final long serialVersionUID = 246957641125257017L;

        @Schema(description = "主键ID")
        private Long id;

        @Schema(description = "标签名称")
        private String tagName;
    }
}
